Interface ACL

All Superinterfaces:
IPCObject
All Known Implementing Classes:
ACLImpl

public interface ACL extends IPCObject
Information provided by the PKI file:

    \class Acl
    
    \brief Acl holds and manipulates AclStatements.
    
    \example network().getDevice("Router0").getProcess("AclProcess").getAcl("aclID")
    
Author:
Auto-generated
  • Method Details

    • addStatement

      boolean addStatement(String statement)
      Information provided by the PKI file:
      
          \brief Adds an ACL statement to this ACL.
          
          \param statement,   the IOS ACL statement. "access-list [this-aclid]" should be omitted.
          Start with "permit, deny, or remark".
          
          \return bool, true if added successfully, otherwise false.
          
              
      Parameters:
      statement - Takes in a parameter of statement
      Returns:
      boolean Returns a boolean
    • addExtStatement

      boolean addExtStatement(boolean bIsIpv6, String protocol, boolean permit, String remoteIp, String remoteMask, int remotePort, String localIp, String localMask, int localPort)
      Information provided by the PKI file:
      
          \brief Adds an ACL statement to this ACL with the specified parameters.
          
          \param protocol, valid protocols are IP, ICMP, TCP, and UDP.
          \param remoteIp, the remote IP adddress.
          \param remoteMask, the remote wildcard mask.
          \param remotePort, the remote port for TCP and UDP.
          \param localIp, the local IP address.
          \param localMask, the local wildcard mask.
          \param localPort, the local port for TCP and UDP.
          
          \return bool, true if added successfully, otherwise false.
          
              
      Parameters:
      bIsIpv6 - Takes in a parameter of bIsIpv6
      protocol - Takes in a parameter of protocol
      permit - Takes in a parameter of permit
      remoteIp - Takes in a parameter of remoteIp
      remoteMask - Takes in a parameter of remoteMask
      remotePort - Takes in a parameter of remotePort
      localIp - Takes in a parameter of localIp
      localMask - Takes in a parameter of localMask
      localPort - Takes in a parameter of localPort
      Returns:
      boolean Returns a boolean
    • removeStatement

      boolean removeStatement(String statement)
      Information provided by the PKI file:
      
          \brief Removes an ACL statement from this ACL.
          
          \param statement    the IOS ACL statement. "access-list [this-aclid]" should be omitted.
          Start with "permit, deny, or remark".
          
          \return bool, true if removed successfully, otherwise false.
          
              
      Parameters:
      statement - Takes in a parameter of statement
      Returns:
      boolean Returns a boolean
    • removeExtStatement

      boolean removeExtStatement(boolean bIsIpv6, String protocol, boolean permit, String remoteIp, String remoteMask, int remotePort, String localIp, String localMask, int localPort)
      Information provided by the PKI file:
      
          \brief Removes the ACL statement from this ACL with the specified parameters.
          
          \param protocol, valid protocols are IP, ICMP, TCP, and UDP.
          \param remoteIp, the remote IP adddress.
          \param remoteMask, the remote wildcard mask.
          \param remotePort, the remote port for TCP and UDP.
          \param localIp, the local IP address.
          \param localMask, the local wildcard mask.
          \param localPort, the local port for TCP and UDP.
          
          \return bool, true if removed successfully, otherwise false.
          
              
      Parameters:
      bIsIpv6 - Takes in a parameter of bIsIpv6
      protocol - Takes in a parameter of protocol
      permit - Takes in a parameter of permit
      remoteIp - Takes in a parameter of remoteIp
      remoteMask - Takes in a parameter of remoteMask
      remotePort - Takes in a parameter of remotePort
      localIp - Takes in a parameter of localIp
      localMask - Takes in a parameter of localMask
      localPort - Takes in a parameter of localPort
      Returns:
      boolean Returns a boolean
    • getStatementAt

      ACLStatement getStatementAt(int index)
      Information provided by the PKI file:
      
          \brief Returns an ACL statement at the specified index.
          
          \param index, the index of the ACL statement.
          
          \return     AclStatement, the ACL statement at the specified index.
          
              
      Parameters:
      index - Takes in a parameter of index
      Returns:
      ACLStatement Returns a ACLStatement
    • getStatementCount

      int getStatementCount()
      Information provided by the PKI file:
      
          \brief Returns the number of ACL statements.
          
          \return int, the number of ACL statements.
          
              
      Returns:
      int Returns a int
    • addRemark

      void addRemark(String remark)
      Information provided by the PKI file:
      
          \brief Adds a remark to this ACL.
          
          \param remark, the remark to be added.
          
              
      Parameters:
      remark - Takes in a parameter of remark
    • getRemark

      String getRemark(int index)
      Information provided by the PKI file:
      
          \brief Returns the remark at the specified index.
          
          \param index, the index of the remark.
          
          \return     string, the remark at the specified index.
          
              
      Parameters:
      index - Takes in a parameter of index
      Returns:
      String Returns a String
    • getRemarkCount

      int getRemarkCount()
      Information provided by the PKI file:
      
          \brief Returns the number of remarks in this ACL.
          
          \return int, the number of remarks in this ACL.
          
              
      Returns:
      int Returns a int
    • getCommandCount

      int getCommandCount()
      Information provided by the PKI file:
      
          \brief Returns the number of ACL commands.
          
          \return int, the number of ACL commands.
          
              
      Returns:
      int Returns a int
    • getCommandAt

      String getCommandAt(int index)
      Information provided by the PKI file:
      
          \brief Returns the ACL command at the specified index.
          
          \param int index, the index of the ACL command.
          
          \return string, the ACL command at the specified index.
          
              
      Parameters:
      index - Takes in a parameter of index
      Returns:
      String Returns a String
    • isExtended

      boolean isExtended()
      Information provided by the PKI file:
      
          \brief Returns true if this ACL is an extended ACL, false if it is a standard ACL.
          
          \return bool, true if this ACL is an extended ACL, false if it is a standard ACL.
          
              
      Returns:
      boolean Returns a boolean
    • getAclId

      String getAclId()
      Information provided by the PKI file:
      
          \brief Returns this ACL's ID.
          
          \return string, this ACL's ID.
          
              
      Returns:
      String Returns a String
    • getExtStatementDataAt

      List<String> getExtStatementDataAt(boolean bIsIpv6, int index)
      Information provided by the PKI file:
      
          \brief Returns a vector of the data of the ACL statement at the specified index.
          
          \param index, the index of the ACL statement of interest.
          
          \return vector<string>, a vector of the data of the ACL statement at the specified index.
          
              
      Parameters:
      bIsIpv6 - Takes in a parameter of bIsIpv6
      index - Takes in a parameter of index
      Returns:
      List<String> Returns a List<String>
    • evaluate

      boolean evaluate(String jsonPdu)
      Information provided by the PKI file:
      
          \brief Evaluates the ACL against a packet/PDU, and returns true if permitted, false otherwise.
          
          \param jsonPdu, the PDU in JSON serialized format
          
          \return bool, true if permitted, false otherwise
          
              
      Parameters:
      jsonPdu - Takes in a parameter of jsonPdu
      Returns:
      boolean Returns a boolean
    • getMatch

      ACLStatement getMatch(String jsonPdu)
      Information provided by the PKI file:
      
          \brief Evaluates the ACL against a packet/PDU, and returns the matched AclStatement.
          
          \param jsonPdu, the PDU in JSON serialized format
          
          \return AclStatement, the matched statement, or null if no match
          
              
      Parameters:
      jsonPdu - Takes in a parameter of jsonPdu
      Returns:
      ACLStatement Returns a ACLStatement